package autokeyboard.data;

import java.io.File;

import javax.swing.filechooser.FileFilter;

public class ExtensionFileFilter extends FileFilter
{
	@Override
	public boolean accept(File f)
	{
		if (f.isDirectory()) return true;

		String extension = Extension.getExtension(f);
		if (extension != null)
		{
			if (extension.equals(Extension.atk))
				return true;
			else return false;
		}
		return false;
	}

	@Override
	public String getDescription()
	{
		return "ATK file only";
	}
}
